<?php

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 * Description of BGroupType
 *
 * @author I062261
 */
class BGroupType extends BEntity {

    //put your code here
    public $groupClass = null;
    public $groupTypeId = null;

    public static function findAll($context) {
        //first get all by spaceId and appId
        $items = parent::findAll($context);
        $types = array();

        if (isset($context['groupClass'])) {
            foreach ($items as $item) {
             if($item->groupClass == $context['groupClass'])   
                 array_push ($types, $item);
            }
            return $types;
        }
        else {
            return $items;
        }
    }

}

?>
